<?php


namespace App\Models\ProductCenter\Models;


use App\Models\ProductCenter\ProductModel;

class BrandModel  extends ProductModel
{
    public $table = 'brand';
    public $fillable = [
        'store_id',
        'name', //varchar(64) COLLATE DEFAULT '' COMMENT '品牌名',
        'parent_id', //int NOT NULL DEFAULT '0' COMMENT '父级id',
        'ids_url', //varchar(255) COLLATE DEFAULT '' COMMENT '当前ids路径',
        'status',
        'create_user', //varchar(64) COLLATE DEFAULT '',
        'create_user_uuid', //varchar(64) COLLATE DEFAULT '',
    ];

    public $casts = [
      'ids_url' => 'array'
    ];

    public function getIdsUrlAttribute($value)
    {
        return $this->strToArrayForVue($value);
    }
}
